package InterviewTest.q0109_isFlipedString;

public class Solution_1 {
    public static void main(String[] args) {
        String a = "abcdef";
        for (int i = 0; i < a.length(); i++) {
            System.out.println(a.substring(0, i) + a.substring(i));
        }

    }

    public boolean isFlipedString(String s1, String s2) {
        for (int i = 0; i < s1.length(); i++) {
            if ((s1.substring(i) + s1.substring(0, i)).equals(s2)) return true;
        }
        return s1.isEmpty() && s2.isEmpty();
    }
}
